package com.xixiake.net.record;

import com.android.volley.Request;
import com.google.gson.annotations.Expose;
import com.google.gson.annotations.SerializedName;
import com.xixiake.net.BaseInput;
import com.xixiake.net.InputKey;

/**
 * Created by c-wanghengli on 2017/6/3.
 */
public class RegisterVerifyCodeRecord {

    public static class Input extends BaseInput<RegisterVerifyCodeRecord>{

        protected Input() {
            super("?c=Auth&a=api_pincode", Request.Method.POST, RegisterVerifyCodeRecord.class);
        }

        @InputKey(name = "phoneno")
        private String phoneno;  // 手机号, 无+86前缀

        @InputKey(name = "scene")
        private int scene;       // 验证使用场景，具体值→  1：注册时，发送验证码     2：忘记密码，重置密码时，发送验证码


        public static BaseInput<RegisterVerifyCodeRecord> buildInput(String phoneno,int scene){
            Input input = new Input();
            input.phoneno = phoneno;
            input.scene = scene;
            return input;
        }
    }

    @Expose
    @SerializedName(value = "errorCode")
    public int errorCode;

    @Expose
    @SerializedName(value = "errorMsg")
    public String errorMsg;

    @Expose
    @SerializedName(value = "data")
    public Info data;

    public static class Info {
        @Expose
        @SerializedName(value = "vcode")
        public int vcode;  // 6位验证码
    }

}
